package com.ct.deadlockdetetor.service.impl;

import com.ct.deadlockdetetor.domain.wait.dto.ProcessWaitDTO;
import com.ct.deadlockdetetor.domain.wait.vo.ProcessWaitVO;
import com.ct.deadlockdetetor.mapper.ProcessWaitMapper;
import com.ct.deadlockdetetor.service.ProcessWaitService;
import com.github.pagehelper.PageHelper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ProcessWaitServiceImpl implements ProcessWaitService {

    @Autowired
    private ProcessWaitMapper processWaitMapper;


    @Override
    public List<ProcessWaitVO> list(ProcessWaitDTO processWaitDTO) {
        PageHelper.startPage(processWaitDTO.getPageNum(), processWaitDTO.getPageSize());
        return processWaitMapper.selectProcessWaitList(processWaitDTO);
    }
}
